﻿
namespace Patterns4Net.Attributes.DesignPatterns
{
    using System;

    /// <summary>
    /// Use this attribute to annotate a type as an implementation of the Adapter design pattern.
    /// </summary>
    [AttributeUsage(AttributeTargets.Class, AllowMultiple = true, Inherited = false)]
    public class AdapterAttribute : Attribute, IPatternAttribute
    {
        /// <summary>
        /// Gets or sets the Target interface which should be implemented by the Adapter. 
        /// If left null, the Adapter does not adapts <see cref="Adaptee"/> to an standard C# interface.
        /// </summary>
        public Type Target { get; set; }

        /// <summary>
        /// Gets or sets the adapter interface.
        /// If left null, the Adapter does not wrap standard C# interface or class.
        /// </summary>
        public Type Adaptee { get; set; }
    }
}
